using System;

namespace BSharp.Compiler.Emit
{
	public class Addi : IntermediateInstruction
	{
		public int Register;
		public int Immediate;

		public Addi (int reg, int immediate)
		{
			Register = reg;
			Immediate = immediate;
		}

		public override void Visit (IntermediateCompiler compiler)
		{
			compiler.Compile (this);
		}

		public override string ToString ()
		{
			return String.Format ("ADDI r{0}, {1}", Register, Immediate);
		}
	}
}

